Skip to content

fix: history 内置Tag 加上统计总数的逻辑 - #4065

Merged
hubin4826 merged 1 commit into
masterfrom
hejiahui/fix/BuildInTag
Jul 31, 2026
Merged

fix: history 内置Tag 加上统计总数的逻辑#4065
hubin4826 merged 1 commit into
masterfrom
hejiahui/fix/BuildInTag

Conversation

@hjhke

@hjhke hjhke commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

第二个合并方式

Copilot AI review requested due to automatic review settings July 29, 2026 02:51
@hjhke hjhke added the need more test 需要更多的测试 label Jul 29, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the HTTP history UI to adjust how built-in tags are derived/filtered (using tag totals) and enables Chromium overlay scrollbars globally in the Electron main process to reduce layout jitter caused by scrollbar appearance/disappearance.

Changes:

  • Remove setBuiltinTagList prop plumbing from HistoryProcess call sites and stop destructuring the setter from useBuiltinTagList.
  • Filter tags returned by HTTPFlowsFieldGroup to exclude certain built-in tags based on Total.
  • Enable global overlay scrollbars via app.commandLine.appendSwitch('enable-features', 'OverlayScrollbars').

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
app/renderer/src/main/src/pages/hTTPHistoryAnalysis/HTTPHistory/HTTPHistoryFilter.tsx Stops passing setBuiltinTagList into HistoryProcess; continues using useBuiltinTagList for table built-in tag options.
app/renderer/src/main/src/components/HTTPHistory.tsx Removes setBuiltinTagList prop from HistoryProcess and changes tag filtering logic to use Total for built-in tags.
app/main/index.js Enables Chromium overlay scrollbars globally to avoid layout reflow/jitter from scrollbars.
Comments suppressed due to low confidence (1)

app/renderer/src/main/src/components/HTTPHistory.tsx:972

  • !!item.Total treats 0 as falsy, so built-in tags with a valid count of 0 will be filtered out. If the intent is to only hide built-in tags with no data, use an explicit numeric comparison to avoid accidentally dropping 0.
        const tags = (rsp.Tags || []).filter(
          (item) => !!item.Value && item.Value !== HTTP_FLOW_FAVORITE_TAG && (!item.Builtin || !!item.Total),
        )

Comment thread app/renderer/src/main/src/components/HTTPHistory.tsx
@github-actions

Copy link
Copy Markdown
Contributor

PR CI 汇总

状态:全部通过

  • ✅ i18n(renderer src/main zh/zh-TW/en)
  • ✅ i18n(engine-link zh/zh-TW/en)
  • ✅ ESLint(renderer src/main)
  • ✅ TypeScript(renderer src/main)
  • ✅ ESLint(engine-link-startup)
  • ✅ TypeScript(engine-link-startup)
  • ✅ 图片/视频体积
  • ✅ Vitest(main / renderer / engine-link;test 同目录·别名·相对路径)
  • ✅ Prettier

由 pull_request test workflow 自动生成

@hjhke
hjhke force-pushed the hejiahui/fix/BuildInTag branch from 9bb7bc6 to c6a95db Compare July 29, 2026 03:47
@hjhke
hjhke force-pushed the hejiahui/fix/BuildInTag branch 2 times, most recently from 9cd4fa9 to 883bd7b Compare July 30, 2026 06:28
@hjhke hjhke changed the title fix: history 内置Tag 加上统计总数的逻辑 开启全局悬浮滚动条避免布局抖动 fix: history 内置Tag 加上统计总数的逻辑 Jul 30, 2026
@Vernon818 Vernon818 added ready and removed need more test 需要更多的测试 labels Jul 30, 2026
@hubin4826
hubin4826 merged commit 6262507 into master Jul 31, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants